package com.ganyu.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ganyu.domain.entity.RoleMenu;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 角色和菜单关联表(RoleMenu)表数据库访问层
 *
 * @author chenxi
 * @since 2022-09-28 10:18:04
 */
@Mapper
public interface RoleMenuMapper extends BaseMapper<RoleMenu> {
    //根据role_id查询menu_id
    List<Long> getMenuId(@Param("roleId") Long roleId);

    //向表中批量插入menu_id
    void insertMenuId(@Param("roleId") Long roleId,@Param("menuId") Long menuId);

}

